﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace HM.DataAccessLayer.DTO
{
    /// <summary>
    /// Class with detailled stats of a player
    /// </summary>
    public class PlayerStatsDetail
    {
        /// <summary>
        /// The Gametype (NL5,NL10)...
        /// </summary>
        public string GameType { get; set; }

        /// <summary>
        /// The value in Euros of the Big Blind for this game type
        /// </summary>
        public double BigBlindValue { get; set; }

        /// <summary>
        /// Numbers of hand played in this type of game
        /// </summary>
        public int NbHands { get; set; }

        /// <summary>
        /// The Amount Won (in Euros)
        /// </summary>
        public double AmountWon { get; set; }


        /// <summary>
        /// The WinRate (BB/100), the number of Big Bets (big blind*2) won in 100 Hands
        /// </summary>
        public double WinRate
        {

            get 
            { 
                double wonBy100 = (AmountWon/NbHands)*100 ;     //the amount won for 100 hands
                return wonBy100 / (BigBlindValue * 2);          //the winrate
            }
        
        }

        /// <summary>
        /// Numbers of hands where Put Volontary into Pot
        /// </summary>
        public int NbHandVpip { get; set; }

        /// <summary>
        /// % of Volountary Put into The Pot
        /// </summary>
        public double VPipPercent
        {
            get { return ((double)NbHandVpip/NbHands)*100;}
        }


    }
}
